package com.suray.basic.wcs.plc.pojo;

/**
 * @author shaozn
 * @date 2020/3/17 - 14:56
 * @Description 电控配置
 */
public class PlcParam {


    private String plcName;
    private int startNum;
    private int endNum;
    private int key;

    /**
     * @param startNum 起始地址位,表示从第几个位置开始读，一般根据
     *                 电控交互表中最左侧序号决定
     * @param endNum   最后一个读取的位置（end - start为读取的总个数）
     */
    public PlcParam(int startNum, int endNum, String plcName) {
        this.plcName = plcName;
        this.startNum = startNum;
        this.endNum = endNum;
    }

    /**
     * @param startNum 起始地址位,表示从第几个位置开始读，一般根据
     *                 电控交互表中最左侧序号决定
     * @param endNum   最后一个读取的位置（end - start为读取的总个数）
     * @param key   plc数据主键值
     */
    public PlcParam(int startNum, int endNum, String plcName, int key) {
        this.plcName = plcName;
        this.startNum = startNum;
        this.endNum = endNum;
        this.key = key;

    }

    public int getKey() {
        return key;
    }

    public int getStartNum() {
        return startNum;
    }

    public void setStartNum(int startNum) {
        this.startNum = startNum;
    }


    public int getEndNum() {
        return endNum;
    }

    public void setEndNum(int endNum) {
        this.endNum = endNum;
    }

    public String getPlcName() {
        return plcName;
    }

    public void setPlcName(String plcName) {
        this.plcName = plcName;
    }
}
